package net.message
{

	import flash.utils.IDataInput;
	
	import net.MessageType;
	import net.handler.GC_Loading_RoleHandler;
	
	import util.Long;

	/**
	 * 文件名：GC_Loading_RoleMessage.as
	 * <p>
	 * 功能：读取用户信息
	 * <p>
	 * 版本：1.0.0
	 * <p>
	 * 作者：Builderd by AppTools
	 * <p>
	 */
	public class GC_Loading_RoleMessage extends BaseMessage
	{
		public var username:String;
		public var chargecount:int;
		public var totalmoeny:int;
		public var vipLevel:int;
		public var gold:int;
		public var silver:int;
		public var exploit:int;
		public var level:uint;
		public var exp:int;
		public var mapId:int;
		public var waveId:int;
		public var writ:int; //军令
		//写入头像
		public var image:String;

		public function GC_Loading_RoleMessage()
		{
			super();
			type = MessageType.GC_Loading_Role;
			handler = new GC_Loading_RoleHandler();
		}

		override public function readMessage(data:IDataInput):void
		{
			//写入角色名称
			username = readString(data);

			//写入充值次数
			chargecount = data.readInt();

			//写入充值总额
			totalmoeny = data.readInt();

			//写入vip等级
			vipLevel = data.readInt();

			//写入金币
			gold = data.readInt();

			//写入银币
			silver = data.readInt();

			//写入功勋
			exploit = data.readInt();

			//写入级别
			level = data.readInt();

			//写入经验
			exp = data.readInt();

			//写入当前地图id
			mapId = data.readInt();

			//写入当前怪物波数
			waveId = data.readInt();

			//写入当前军令数
			writ = data.readInt();
			
			//写入头像
			image = readString(data);
		}
	}
}
